package com.project.web.order.service.impl.app;

import com.project.web.course.service.impl.common.BaseServiceImpl;
import com.project.web.order.mapper.app.ProductMapper;
import com.project.web.order.model.app.Product;
import com.project.web.order.service.app.ProductService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 商品业务实现类
 *
 * @Author: wyy
 * @Date: 2021-02-02 01:20
 */
@Service("productServiceImpl")
public class ProductServiceImpl extends BaseServiceImpl<Product, Long> implements ProductService {

    /**
     * 日志工具类
     */
    public static final Logger log = LoggerFactory.getLogger(ProductServiceImpl.class);

    @Autowired
    private ProductMapper productMapper;

    /**
     * 查询已上架商品
     *
     * @return
     */
    @Override
    public List<Product> getProductsOfNormal() {
        return productMapper.getProductsOfNormal();
    }
}
